// pages/user/index.js
Page({
  data: {
    userInfo: {},
    star: []
  },
  onShow() {
    const userInfo = wx.getStorageSync('userinfo')
    const star = wx.getStorageSync('star') || []
    this.setData({
      userInfo,
      star
    })
  }
})